<link rel="stylesheet" href="__PUBLIC__/Home/css/menu.css">
<div class="fixed-main-menu">

    <?php

    $home_default_local_id = (!empty($_GET['top_local_id']) && $_GET['top_local_id'] != '11') ? $_GET['top_local_id'] : $default_local_id;

    ?>
    <?php if ($_GET['local_id'] == '11'){ ?>
        <a href="{:url('store/index',['local_id' => $home_default_local_id, 'top_local_id' => 11])}" class="home <?php echo CONTROLLER_NAME == 'Store' ? 'active' : ''; ?>"><span></span>
            <p>首页</p>
        </a>
    <?php }else { ?>
        <a href="{:url('store/index',['local_id' => $storeData['local_id']])}" class="home <?php echo CONTROLLER_NAME == 'Store' ? 'active' : ''; ?>"><span></span>
            <p>首页</p>
        </a>
    <?php } ?>

    <?php if ($_GET['local_id'] == '11'){ ?>
    <a href="{:url('category/index', ['local_id' => $home_default_local_id, 'top_local_id' => 11])}" class="category <?php echo CONTROLLER_NAME == 'Category' ? 'active' : ''; ?>"><span></span>
        <p>分类</p></a>
    <?php }else { ?>
    <a href="{:url('category/index', ['local_id' => $storeData['local_id']])}" class="category <?php echo CONTROLLER_NAME == 'Category' ? 'active' : ''; ?>"><span></span>
        <p>分类</p></a>
    <?php } ?>

    <?php if ($_GET['local_id'] == '11'){ ?>
    <a href="{:url('store/index', ['local_id' => '11'])}" class="store-way <?php echo ($_GET['local_id'] == '11') ? 'active' : '';?>"><span></span><p>全国送</p></a>
    <?php }else { ?>
    <?php $top_local_id = (!empty($_GET['local_id'])) ? $_GET['local_id'] : $storeData['local_id']; ?>
    <a href="{:url('store/index', ['local_id' => '11','top_local_id' => $top_local_id])}" class="store-way <?php echo ($_GET['local_id'] == '11') ? 'active' : '';?>"><span></span><p>全国送</p></a>
    <?php } ?>

    <a href="{:url('carts/cart')}" class="cart <?php echo CONTROLLER_NAME == 'Carts' ? 'active' : ''; ?> clickable_shou"><span></span>
        <p>购物车</p>

            <if condition="userCartNum()">
                <label class="public-cart-number">{:userCartNum()}</label>
            </if>
    </a>
    <a href="{:url('Member/index')}" class="mine <?php echo CONTROLLER_NAME == 'Member' ? 'active' : ''; ?> clickable_shou" id="menuMemberPopup"><span></span><p>我的</p></a>
</div>
<include file="Public/bind_phone"/>
<script type="text/javascript">
    $(".clickable_shou").click(function(e){
        _global.checkPhoner.reset();
        _global.checkPhoner.run(e, $(this).attr('href'));
    });
</script>

